package pinyinJava.persistence;

import pinyinJava.bean.DBean;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.ArrayList;

public interface IDbPersistence {

    Connection open(String path) throws SQLException;

    void close(Connection connection) throws SQLException;

    void save(Connection connection, String tName, ArrayList<DBean> dList) throws SQLException;

    ArrayList<DBean> read(Connection connection, String tName) throws SQLException;

    ArrayList<String> tables(Connection connection) throws SQLException;
}
